Skip to content

Commit

Permalink
Update compiler.lua (#3119)
Browse files Browse the repository at this point in the history
  • Loading branch information
deltamolfar authored Aug 12, 2024
1 parent 0322687 commit 57dd018
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lua/entities/gmod_wire_expression2/base/compiler.lua
Original file line number Diff line number Diff line change
Expand Up @@ -679,7 +679,7 @@ local CompileVisitors = {
end
end

if self.strict and not self.scope:IsGlobalScope() then
if self.strict and not (self.scope:IsGlobalScope() or (self.include and self.scope:Depth() == 1)) then
self:Warning("Functions should be in the top scope, nesting them does nothing", trace)
end

Expand Down

0 comments on commit 57dd018

Please sign in to comment.