Ticket #10 (closed enhancement: fixed)

Opened 2 years ago

Last modified 2 months ago

Improve the parser recovery

Reported by: asterite Assigned to:
Priority: minor Component: descent.core
Version: Keywords:
Cc:

Description (Last modified by asterite)

Currently the parser, ported from DMD, dosen't have a good syntax error recovery. Say you have this source:

class C {
	
	void method1() {
		
	}
	
	void method2() {
		
	}
	
	// ...
	
	void methodN() {
		
	}
	
}

Then you decide to turn method1 into a templated method, so you write the first parenthesis:

class C {

	void method1(() {
		
	}
	
	void method2() {
		
	}
	
	// ...
	
	void methodN() {
		
	}
	
}

This causes the parser to return an empty AST for the module. The outline view will suddenly get blank until typing the correct information. The parser should be enhanced to improve recovery of the AST in this and other cases.

Change History

02/19/07 22:44:32 changed by asterite

  • description changed.

07/06/08 13:44:19 changed by asterite

  • status changed from new to closed.
  • resolution set to fixed.