hashicorp / hcl2

Former temporary home for experimental new version of HCL
https://github.com/hashicorp/hcl
Mozilla Public License 2.0
373 stars 66 forks source link

Incorrect handling of "heredocs" #21

Closed apparentlymart closed 6 years ago

apparentlymart commented 6 years ago
Error: Missing newline after attribute definition

  on .terraform/init-from-module/root/Azure-terraform-azurerm-computegroup-c1a7c62/main.tf line 89:
  84:     settings = <<SETTINGS
  85:     {
  86:         "commandToExecute": "${var.cmd_extension}"
  87:     }
  88:     SETTINGS
  89:   }

An attribute definition must end with a newline.

Looks like this issue arises because the closing SETTINGS marker consumes the newline that the attribute parser normally uses to mark the end of a newline.

apparentlymart commented 6 years ago

This was fixed in 7d6ed4d8f315f66b6c64389c00a661d16c4161ef.