Skip to content

Latest commit

 

History

History
46 lines (29 loc) · 986 Bytes

File metadata and controls

46 lines (29 loc) · 986 Bytes
title BCP072
description This symbol cannot be referenced here. Only other parameters can be referenced in parameter default values.
ms.topic reference
ms.custom devx-track-bicep
ms.date 10/30/2025

Bicep diagnostic code - BCP072

This diagnostic occurs when you reference a variable in parameter default values.

Description

This symbol cannot be referenced here. Only other parameters can be referenced in parameter default values.

Level

Error

Solution

Reference another parameter instead.

Examples

The following example raises the diagnostic because the parameter default value references a variable:

param foo string = bar

var bar = 'HelloWorld!'

You can fix the diagnostic by referencing another parameter:

param foo string = bar
param bar string = 'HelloWorld!'

output outValue string = foo

Next steps

For more information about Bicep diagnostics, see Bicep core diagnostics.