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

Method project

src/main/java/wyil/lang/WyilFile.java:793–806  ·  view source on GitHub ↗
(Tuple<Decl.Variable> decls)

Source from the content-addressed store, hash-verified

791 }
792
793 public static WyilFile.Type project(Tuple<Decl.Variable> decls) {
794 switch(decls.size()) {
795 case 0:
796 return WyilFile.Type.Void;
797 case 1:
798 return decls.get(0).getType();
799 default:
800 WyilFile.Type[] types = new WyilFile.Type[decls.size()];
801 for(int i=0;i!=types.length;++i) {
802 types[i] = decls.get(i).getType();
803 }
804 return new WyilFile.Type.Tuple(types);
805 }
806 }
807
808 /**
809 * Get the body associated with this callable declaration which is either a

Callers

nothing calls this directly

Calls 3

sizeMethod · 0.65
getTypeMethod · 0.65
getMethod · 0.65

Tested by

no test coverage detected