@@ -234,25 +234,22 @@ protected void getGhostFunction(String value, CtElement element) {
234234 protected void handleAlias (String value , CtElement element ) {
235235 try {
236236 AliasDTO a = RefinementsParser .getAliasDeclaration (value );
237-
238- if (a != null ) {
239- String klass = null ;
240- String path = null ;
241- if (element instanceof CtClass ) {
242- klass = ((CtClass <?>) element ).getSimpleName ();
243- path = ((CtClass <?>) element ).getQualifiedName ();
244- } else if (element instanceof CtInterface <?>) {
245- klass = ((CtInterface <?>) element ).getSimpleName ();
246- path = ((CtInterface <?>) element ).getQualifiedName ();
247- }
248- if (klass != null && path != null ) {
249- a .parse (path );
250- AliasWrapper aw = new AliasWrapper (a , factory , WILD_VAR , context , klass , path );
251- context .addAlias (aw );
252- }
237+ String klass = null ;
238+ String path = null ;
239+ if (element instanceof CtClass ) {
240+ klass = ((CtClass <?>) element ).getSimpleName ();
241+ path = ((CtClass <?>) element ).getQualifiedName ();
242+ } else if (element instanceof CtInterface <?>) {
243+ klass = ((CtInterface <?>) element ).getSimpleName ();
244+ path = ((CtInterface <?>) element ).getQualifiedName ();
245+ }
246+ if (klass != null && path != null ) {
247+ a .parse (path );
248+ AliasWrapper aw = new AliasWrapper (a , factory , WILD_VAR , context , klass , path );
249+ context .addAlias (aw );
253250 }
254251 } catch (ParsingException e ) {
255- ErrorHandler .printCustomError ( element , e .getMessage (), errorEmitter );
252+ ErrorHandler .printSyntaxError ( e .getMessage (), value , element , errorEmitter );
256253 return ;
257254 // e.printStackTrace();
258255 }
0 commit comments