1
1
mirror of https://github.com/github/semantic.git synced 2024-12-20 21:31:48 +03:00

Rename InstanceOf to Instance

Co-Authored-By: Rick Winfrey <rick.winfrey@gmail.com>
This commit is contained in:
joshvera 2018-12-13 13:14:45 -05:00
parent a6657cc679
commit 0eaa362b3a

View File

@ -96,8 +96,7 @@ instance Evaluatable Method where
declare (Declaration self) Default emptySpan Nothing declare (Declaration self) Default emptySpan Nothing
fmap (self :) . for methodParameters $ \paramNode -> do fmap (self :) . for methodParameters $ \paramNode -> do
param <- maybeM (throwEvalError $ NoNameError paramNode) (declaredName paramNode) param <- maybeM (throwEvalError $ NoNameError paramNode) (declaredName paramNode)
-- TODO: Should we treat params as a special Relation? I've left this as an `InstanceOf` for now. param <$ declare (Declaration param) Default span Nothing
param <$ declare (Declaration param) InstanceOf span Nothing
addr <- lookupDeclaration (Declaration name) addr <- lookupDeclaration (Declaration name)
v <- function name params methodBody associatedScope v <- function name params methodBody associatedScope
@ -211,8 +210,7 @@ instance Evaluatable PublicFieldDefinition where
span <- ask @Span span <- ask @Span
propertyName <- maybeM (throwEvalError $ NoNameError publicFieldPropertyName) (declaredName publicFieldPropertyName) propertyName <- maybeM (throwEvalError $ NoNameError publicFieldPropertyName) (declaredName publicFieldPropertyName)
-- withScope instanceScope $ do declare (Declaration propertyName) Instance span Nothing
declare (Declaration propertyName) InstanceOf span Nothing
slot <- lookupDeclaration (Declaration propertyName) slot <- lookupDeclaration (Declaration propertyName)
value <- eval publicFieldValue value <- eval publicFieldValue
assign slot value assign slot value