equal
deleted
inserted
replaced
666 |
666 |
667 @Override |
667 @Override |
668 public Void visitModuleTarget(ModuleTarget_attribute attr, Void ignore) { |
668 public Void visitModuleTarget(ModuleTarget_attribute attr, Void ignore) { |
669 println("ModuleTarget:"); |
669 println("ModuleTarget:"); |
670 indent(+1); |
670 indent(+1); |
671 print("os_name: #" + attr.os_name_index); |
671 print("target_platform: #" + attr.target_platform_index); |
672 if (attr.os_name_index != 0) { |
672 if (attr.target_platform_index != 0) { |
673 tab(); |
673 tab(); |
674 print("// " + getOSName(attr)); |
674 print("// " + getTargetPlatform(attr)); |
675 } |
675 } |
676 println(); |
676 println(); |
677 print("os_arch: #" + attr.os_arch_index); |
677 indent(-1); |
678 if (attr.os_arch_index != 0) { |
678 return null; |
679 tab(); |
679 } |
680 print("// " + getOSArch(attr)); |
680 |
681 } |
681 private String getTargetPlatform(ModuleTarget_attribute attr) { |
682 println(); |
682 try { |
683 indent(-1); |
683 return constant_pool.getUTF8Value(attr.target_platform_index); |
684 return null; |
|
685 } |
|
686 |
|
687 private String getOSName(ModuleTarget_attribute attr) { |
|
688 try { |
|
689 return constant_pool.getUTF8Value(attr.os_name_index); |
|
690 } catch (ConstantPoolException e) { |
|
691 return report(e); |
|
692 } |
|
693 } |
|
694 |
|
695 private String getOSArch(ModuleTarget_attribute attr) { |
|
696 try { |
|
697 return constant_pool.getUTF8Value(attr.os_arch_index); |
|
698 } catch (ConstantPoolException e) { |
684 } catch (ConstantPoolException e) { |
699 return report(e); |
685 return report(e); |
700 } |
686 } |
701 } |
687 } |
702 |
688 |