1. Awaken what lies in the heart of your swarm. The 17th Techtree Contest has arrived!
    Dismiss Notice
  2. The Hive Workshop is launching its first HD modelling contest. How HD should it be?
    Dismiss Notice
  3. Check out the Staff Job Openings thread.
    Dismiss Notice
Dismiss Notice
Hive 3 Remoosed BETA - NOW LIVE. Go check it out at BETA Hive Workshop! Post your feedback in this new forum BETA Feedback.
Dismiss Notice
60,000 passwords have been reset on July 8, 2019. If you cannot login, read this.

PJass updates

Discussion in 'Warcraft Editing Tools' started by LeP, Oct 25, 2014.

  1. LeP

    LeP

    Joined:
    Feb 13, 2008
    Messages:
    484
    Resources:
    0
    Resources:
    0
    Thanks for testing. Indeed the fix is very easy but it's not pjass' domain to do so.
    Here is a fresh pjass version which reports this.

    Code (Text):

    $ cat tests/should-fail/native-as-code.j
    native TriggerSyncStart takes nothing returns nothing

    function foo takes nothing returns nothing
        local code bla = function TriggerSyncStart
    endfunction

    $ ./pjass tests/should-fail/native-as-code.j
    tests/should-fail/native-as-code.j:4: Cannot use native 'TriggerSyncStart' as code
    tests/should-fail/native-as-code.j failed with 1 error
    Parse failed: 1 error total

     
     

    Attached Files:

  2. Aniki

    Aniki

    Joined:
    Nov 7, 2014
    Messages:
    565
    Resources:
    6
    Tools:
    1
    Maps:
    1
    Spells:
    1
    JASS:
    3
    Resources:
    6
    More nit-picking:

    Hex literals using the '0X' prefix are not recognized:
    Code (vJASS):

    globals
        integer a1 = 0x0
        integer a2 = 0X0 // error
    endglobals
     


    Variable shadowing interacting with constant function:
    Code (vJASS):

    globals
        integer x
    endglobals
    constant function foo takes nothing returns nothing
        local integer x
        set x = 5 // Assignment to global variable x in constant function
    endfunction
     
     
  3. LeP

    LeP

    Joined:
    Feb 13, 2008
    Messages:
    484
    Resources:
    0
    Resources:
    0
    Cheers m8 keep 'em coming.
     

    Attached Files:

  4. Prometheus3375

    Prometheus3375

    Joined:
    Jul 20, 2018
    Messages:
    113
    Resources:
    0
    Resources:
    0
    Can you, please, add link to the readme or repo to the main post?
     
  5. Prometheus3375

    Prometheus3375

    Joined:
    Jul 20, 2018
    Messages:
    113
    Resources:
    0
    Resources:
    0
    I believe, last version is bugged.
    Consider this file.
    Version 02.08.2020 gives a syntax error.
    Version 04.08.2020 crashes.
    @LeP, can you look at this?
     

    Attached Files:

  6. LeP

    LeP

    Joined:
    Feb 13, 2008
    Messages:
    484
    Resources:
    0
    Resources:
    0
    Should be fixed. Thanks for the report.
     

    Attached Files: