Skip to content

Commit

Permalink
Create a better error message for objects not being in the moduleset.
Browse files Browse the repository at this point in the history
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=171067075
  • Loading branch information
xingyuzhou authored and dimvar committed Oct 5, 2017
1 parent 43fae6a commit bc9cf44
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/com/google/javascript/rhino/jstype/NamedType.java
Expand Up @@ -360,7 +360,8 @@ private void handleUnresolvedType(
boolean isForwardDeclared =
ignoreForwardReferencedTypes && registry.isForwardDeclaredType(reference);
if (!isForwardDeclared) {
warning(t, "Bad type annotation. Unknown type " + reference);
String msg = "Bad type annotation. Unknown type " + reference;
warning(t, msg);
} else {
setReferencedType(new NoResolvedType(registry, getReferenceName(), getTemplateTypes()));
if (validator != null) {
Expand Down

0 comments on commit bc9cf44

Please sign in to comment.