Add support for negative constants in external initialisers.
This commit is contained in:
		
							parent
							
								
									a01523a893
								
							
						
					
					
						commit
						b1576e2c77
					
				
					 1 changed files with 9 additions and 1 deletions
				
			
		|  | @ -373,7 +373,15 @@ loop: | |||
| 		return subseq(c,PLUS,INCBEF); | ||||
| 
 | ||||
| 	case MINUS: | ||||
| 		return subseq(c,MINUS,DECBEF); | ||||
| 		/* avoid peeking a name, which could overwrite
 | ||||
| 		 * an already set bsym. */ | ||||
| 		if (ctab[peekc = spnextchar()] == DIGIT) { | ||||
| 			getnum(); | ||||
| 			cval = -cval; | ||||
| 			return CON; | ||||
| 		} else { | ||||
| 			return subseq(c,MINUS,DECBEF); | ||||
| 		} | ||||
| 
 | ||||
| 	case LESS: | ||||
| 		if (subseq(c,0,1)) | ||||
|  |  | |||
		Loading…
	
	Add table
		
		Reference in a new issue