Skip to content

Commit cfddfb1

Browse files
committed
default to false if attr is not present on rule
1 parent c8165c7 commit cfddfb1

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

rust/private/rustc.bzl

+1-1
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,7 @@ ErrorFormatInfo = provider(
5757
)
5858

5959
def _use_worker(ctx):
60-
return ctx.attr._use_worker[BuildSettingInfo].value
60+
return hasattr(ctx.attr, "_use_worker") and ctx.attr._use_worker[BuildSettingInfo].value
6161

6262
def _get_rustc_env(ctx, toolchain):
6363
"""Gathers rustc environment variables

0 commit comments

Comments
 (0)