Skip to content

Commit d0dd75e

Browse files
committed
(WIP) QualifiedMethodExpression -- minor formatting fixes
1 parent 7967efb commit d0dd75e

2 files changed

Lines changed: 11 additions & 4 deletions

File tree

Clojure/Clojure/CljCompiler/Ast/InvokeExpr.cs

Lines changed: 10 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -243,7 +243,11 @@ static Expr ToHostExpr(ParserContext pcon, QualifiedMethodExpr qmfexpr, Symbol t
243243
switch (qmfexpr.Kind)
244244
{
245245
case QualifiedMethodExpr.EMethodKind.CTOR:
246-
return new NewExpr(qmfexpr.MethodType, (ConstructorInfo)method, HostExpr.ParseArgs(pcon, RT.seq(args)), (IPersistentMap)Compiler.SourceSpanVar.deref());
246+
return new NewExpr(
247+
qmfexpr.MethodType,
248+
(ConstructorInfo)method,
249+
HostExpr.ParseArgs(pcon, RT.seq(args)),
250+
(IPersistentMap)Compiler.SourceSpanVar.deref());
247251

248252
case QualifiedMethodExpr.EMethodKind.INSTANCE:
249253
return new InstanceMethodExpr(
@@ -255,7 +259,7 @@ static Expr ToHostExpr(ParserContext pcon, QualifiedMethodExpr qmfexpr, Symbol t
255259
Compiler.munge(qmfexpr.MethodName),
256260
(MethodInfo)method,
257261
null, // TODO: is there a way to pass type args here?
258-
HostExpr.ParseArgs(pcon, RT.seq(RT.next(args))),
262+
HostExpr.ParseArgs(pcon, RT.next(args)),
259263
tailPosition);
260264

261265
default:
@@ -276,7 +280,10 @@ static Expr ToHostExpr(ParserContext pcon, QualifiedMethodExpr qmfexpr, Symbol t
276280
switch (qmfexpr.Kind)
277281
{
278282
case QualifiedMethodExpr.EMethodKind.CTOR:
279-
return new NewExpr(qmfexpr.MethodType, HostExpr.ParseArgs(pcon, RT.seq(args)), (IPersistentMap)Compiler.SourceSpanVar.deref());
283+
return new NewExpr(
284+
qmfexpr.MethodType,
285+
HostExpr.ParseArgs(pcon, RT.seq(args)),
286+
(IPersistentMap)Compiler.SourceSpanVar.deref());
280287

281288
case QualifiedMethodExpr.EMethodKind.INSTANCE:
282289
return new InstanceMethodExpr(

Clojure/Clojure/CljCompiler/Compiler.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2119,7 +2119,7 @@ private static Expr AnalyzeSymbol(Symbol symbol)
21192119
return new StaticFieldExpr((string)SourceVar.deref(), (IPersistentMap)Compiler.SourceSpanVar.deref(), tag, t, symbol.Name, finfo);
21202120
else if ((pinfo = Reflector.GetProperty(t, symbol.Name, true)) != null)
21212121
return new StaticPropertyExpr((string)SourceVar.deref(), (IPersistentMap)Compiler.SourceSpanVar.deref(), tag, t, symbol.Name, pinfo);
2122-
//else return new QualifiedMethodExpr(t, symbol);
2122+
else return new QualifiedMethodExpr(t, symbol);
21232123
}
21242124
//throw new InvalidOperationException(string.Format("Unable to find static field: {0} in {1}", symbol.Name, t));
21252125
}

0 commit comments

Comments
 (0)