Jump to content
Sign in to follow this  
djulien

Asm Comment Parsing Errors

Recommended Posts

Bug description:

BoostC is not correctly skipping over comments within asm blocks.

 

Example code:

#include <system.h>

void main(void)
{
asm
{
	nop; //comment with asm in it
	nop; //comment with asmprefix in it
	nop; //comment with suffixasm in it
	nop; //comment without it
}
}

 

The first 3 "nop" lines will generate the following error:

file(line): error: error in built-in assembly

 

Expected behavior:

Compiler should ignore all text on a line after ";" or maybe "//" (depending on how that is supposed to work). If for some reason it must scan comments for the token "asm", then it should at least ignore it when it is part of a larger string (second and third "nop" lines in the example code).

 

Is the problem 100% reproduceable:

yes

 

Compiler:

BoostC

 

Compiler version:

7.10

 

Target device:

PIC16F1827, etc.

 

OS:

Windows XP

 

don

Share this post


Link to post
Share on other sites

Join the conversation

You are posting as a guest. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
Sign in to follow this  

×
×
  • Create New...