Skip to content

Commit

Permalink
Fix warnings
Browse files Browse the repository at this point in the history
  • Loading branch information
migueldeicaza committed Sep 27, 2023
1 parent e8f110e commit e9c4cc5
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 3 deletions.
2 changes: 0 additions & 2 deletions Sources/SwiftGodotMacroLibrary/MacroExport.swift
Original file line number Diff line number Diff line change
Expand Up @@ -98,8 +98,6 @@ public struct GodotExport: PeerMacro {
throw GodotMacroError.expectedIdentifier(singleVar)
}
let varName = ips.identifier.text
let setterName = "_mproxy_set_\(varName)"
let getterName = "_mproxy_get_\(varName)"

if let accessors = last.accessorBlock {
if accessors.as (CodeBlockSyntax.self) != nil {
Expand Down
2 changes: 1 addition & 1 deletion Sources/SwiftGodotMacroLibrary/SceneTreeMacro.swift
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ public struct SceneTreeMacro: AccessorMacro {
public static func expansion(of node: AttributeSyntax,
providingAccessorsOf declaration: some DeclSyntaxProtocol,
in context: some MacroExpansionContext) throws -> [AccessorDeclSyntax] {
guard let argument = node.argument?.as(TupleExprElementListSyntax.self)?.first?.expression else {
guard let argument = node.arguments?.as(LabeledExprListSyntax.self)?.first?.expression else {
let missingArgErr = Diagnostic(node: node.root, message: ProviderDiagnostic.missingPathArgument)
context.diagnose(missingArgErr)
return [
Expand Down

0 comments on commit e9c4cc5

Please sign in to comment.