Wayne
Wayne

Reputation: 99

Error Reporting when translating between ASTs

I'm doing some translations between two ADTs but when I use data types that don't exist in the current scope it doesn't throw any errors, any suggestions on how to fix this?

EDIT:

Context: Say I have the following module to translate some SQL constructs to HQL, in the context below, the Python construct doesn't exist in this scope, but I don't get the error report or linting.

module lang::sql::translations::translate2b::TranslateDML

import lang::sql::ast::SQL;
import lang::hql::ast::Module;

extend lang::sql::translations::translate2b::TranslateExpressions;


public HQL translateDeclaration(Python sqlCmd) {
  switch(sqlCmd) {
    default: throw "Unhandled HQL: <sqlCmd>";
  }
}

Upvotes: 1

Views: 55

Answers (0)

Related Questions