[Java] typedefs in types.hal files no longer mistakenly appear in the generated

makefile.

Bug: 31678014
Test: run hidl_test, hidl_test_java
Change-Id: I60dc8b4dc5c5482e01887ab3d991554beab04ff1
diff --git a/main.cpp b/main.cpp
index a389f2c..687440c 100644
--- a/main.cpp
+++ b/main.cpp
@@ -230,6 +230,10 @@
             Scope *rootScope = typesAST->scope();
 
             for (const auto &type : rootScope->getSubTypes()) {
+                if (type->isTypeDef()) {
+                    continue;
+                }
+
                 generateMakefileSectionForLanguageAndType(
                         out,
                         coordinator,