MCPcopy Create free account
hub / github.com/Whiley/WhileyCompiler / toString

Method toString

src/main/java/wyil/lang/WyilFile.java:683–708  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

681 }
682
683 @Override
684 public String toString() {
685 String r = "import ";
686 if (hasFrom()) {
687 r += WyilFile.toString(getNames());
688 r += " from ";
689 }
690 Tuple<Identifier> path = getPath();
691 for (int i = 0; i != path.size(); ++i) {
692 if (i != 0) {
693 r += ".";
694 }
695 Identifier component = path.get(i);
696 if (component == null) {
697 r += "*";
698 } else {
699 r += component.get();
700 }
701 }
702 if (hasWith()) {
703 r += " with ";
704 r += WyilFile.toString(getNames());
705 }
706
707 return r;
708 }
709
710 public static final Descriptor DESCRIPTOR_0a = new Descriptor(Operands.ONE, Data.ZERO, "DECL_import") {
711 @Override

Callers

nothing calls this directly

Calls 8

hasFromMethod · 0.95
toStringMethod · 0.95
getNamesMethod · 0.95
getPathMethod · 0.95
getMethod · 0.95
hasWithMethod · 0.95
sizeMethod · 0.65
getMethod · 0.65

Tested by

no test coverage detected