Skip to content

Commit

Permalink
I broke refactoring imports. Fixing it
Browse files Browse the repository at this point in the history
  • Loading branch information
MarcWeber committed Nov 26, 2010
1 parent 9fedafd commit 2b0e882
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion src/main/scala/org/ensime/protocol/SwankJsonProtocol.scala
Expand Up @@ -248,7 +248,6 @@ trait SwankJsonProtocol extends Protocol[JValue] {
def toWF(value :RPCResult):JValue = {
value match {
case RPCResultNull => JInt(0) // Vim can't parse null
case RPCResultAny(any:Any) => throw new Exception("TODO")
case RPCResultNoteList(nl:NoteList) => toWF(nl)
case RPCResultNote(note:Note) => throw new Exception("not used")
case RPCResultNamedTypeMemberInfo(namedTypeMember:NamedTypeMemberInfoLight) => toWF(namedTypeMember)
Expand All @@ -262,6 +261,7 @@ trait SwankJsonProtocol extends Protocol[JValue] {
case RPCResultImportSuggestions(l: ImportSuggestions) => toWF(l)
case RPCResultBool(b: Boolean) => toWF(b)
case RPCResultTypeInspectInfo(t: TypeInspectInfo) => toWF(t)
case RPCResultRefactorEffect(b: RefactorEffect) => toWF(b)
case RPCResultRefactorFailure(b: RefactorFailure) => toWF(b)
case RPCResultRefactorResult(b: RefactorResult) => toWF(b)
case RPCResultProjectConfig(c: ProjectConfig) => toWF(c)
Expand Down
2 changes: 1 addition & 1 deletion src/main/scala/org/ensime/protocol/SwankProtocol.scala
Expand Up @@ -388,7 +388,6 @@ trait SwankProtocol extends Protocol[SExp] {
def toWF(value :RPCResult):SExp = {
value match {
case RPCResultNull => toWF(null)
case RPCResultAny(any:Any) => throw new Exception("TODO")
case RPCResultNoteList(nl:NoteList) => toWF(nl)
case RPCResultNote(note:Note) => throw new Exception("not used")
case RPCResultNamedTypeMemberInfo(namedTypeMember:NamedTypeMemberInfoLight) => toWF(namedTypeMember)
Expand All @@ -402,6 +401,7 @@ trait SwankProtocol extends Protocol[SExp] {
case RPCResultImportSuggestions(l: ImportSuggestions) => toWF(l)
case RPCResultBool(b: Boolean) => toWF(b)
case RPCResultTypeInspectInfo(t: TypeInspectInfo) => toWF(t)
case RPCResultRefactorEffect(effect:RefactorEffect) => toWF(effect)
case RPCResultRefactorFailure(b: RefactorFailure) => toWF(b)
case RPCResultRefactorResult(b: RefactorResult) => toWF(b)
case RPCResultProjectConfig(c: ProjectConfig) => toWF(c)
Expand Down
2 changes: 1 addition & 1 deletion src/main/scala/org/ensime/server/Project.scala
Expand Up @@ -18,7 +18,7 @@ import scala.collection.mutable.{ LinkedHashMap }
// client. See Protocol implementations to find out how they are encoded
abstract sealed class RPCResult
case object RPCResultNull extends RPCResult
case class RPCResultAny(any:Any) extends RPCResult
case class RPCResultRefactorEffect(any:RefactorEffect) extends RPCResult
case class RPCResultNoteList(nl:NoteList) extends RPCResult
case class RPCResultNote(note:Note) extends RPCResult
case class RPCResultNamedTypeMemberInfo(namedTypeMember:NamedTypeMemberInfoLight) extends RPCResult
Expand Down
4 changes: 2 additions & 2 deletions src/main/scala/org/ensime/server/Refactoring.scala
Expand Up @@ -63,9 +63,9 @@ trait RefactoringController { self: Analyzer =>
result match {
case Right(effect) => {
effects(procedureId) = effect
project ! RPCResultEvent(RPCResultAny(effect), callId)
project ! RPCResultEvent(RPCResultRefactorEffect(effect), callId)
}
case Left(f) => project ! RPCResultEvent(RPCResultAny(f), callId)
case Left(f) => project ! RPCResultEvent(RPCResultRefactorFailure(f), callId)
}
}

Expand Down

0 comments on commit 2b0e882

Please sign in to comment.