#1 #define macros with arguments

None
closed
None
5
2012-11-01
2002-05-14
No

If I assemble the file below, I get a
test1.asm:11:Error [103] parse error
Line 11 is the one with movlw.

This works fine with mplab. This is with gputils
0.10.3.

Thanks,
David

------ cut here -------
        list      p=16f877

        __CONFIG 0

#define L7(val)  ((val) & 0x7f)

        RADIX   DEC

        org     0x000
        nop
        movlw   L7(123)
        goto    $

        END

Discussion

  • Craig Franklin

    Craig Franklin - 2002-05-15

    Logged In: YES
    user_id=91596

    gpasm does not yet support #define macros with arguments. I
    will see what I can do for the next release. Thanks.

     
  • Borut Ražem

    Borut Ražem - 2012-10-16
    • Description has changed:

    Diff:

    --- old
    +++ new
    @@ -8,6 +8,7 @@
     Thanks,
     David
    
    +~~~~~~
     ------ cut here -------
             list      p=16f877
    
    @@ -23,3 +24,4 @@
             goto    $
    
             END
    +~~~~~~
    
    • assigned_to: Borut Ražem
    • milestone: --> Next_Release_(example)

    • Description has changed:

    Diff:

    --- old
    +++ new
    @@ -14,7 +14,7 @@
    
             __CONFIG 0
    
    -#define L7(val)  ((val) & 0x7f)
    +#define L7(val)  ((val) & 0x7f)
    
             RADIX   DEC
    
     
  • Borut Ražem

    Borut Ražem - 2012-10-16

    Fixed in preprocessor branch, svn revision #844.

    Borut

     
  • Borut Ražem

    Borut Ražem - 2012-11-01
    • status: open --> closed
     
  • Borut Ražem

    Borut Ražem - 2012-11-01

    Fix merged to HEAD in svn revision #867.

    Borut

     


Anonymous

Cancel  Add attachments





Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:

JavaScript is required for this form.





No, thanks