[PlaygroundTransform] Replace "$builtin" with "__builtin".

Currently, the playground transform requires the use of dollar-identifiers as the functions are prefixed with "$builtin".
This commit removes that requirement by replacing "$builtin" with "__builtin".
This aligns with the PC macro.

This addresses <rdar://problem/36031860>.
This commit is contained in:
Connor Wakamo
2017-12-18 10:32:09 -08:00
parent 99cc3223e6
commit 451778591e
35 changed files with 223 additions and 223 deletions

View File

@@ -1,6 +1,6 @@
// RUN: %empty-directory(%t)
// RUN: cp %s %t/main.swift
// RUN: %target-build-swift -Xfrontend -pc-macro -Xfrontend -playground-high-performance -Xfrontend -playground -Xfrontend -debugger-support -o %t/main %S/Inputs/PCMacroRuntime.swift %t/main.swift %S/../PlaygroundTransform/Inputs/PlaygroundsRuntime.swift
// RUN: %target-build-swift -Xfrontend -pc-macro -Xfrontend -playground-high-performance -Xfrontend -playground -o %t/main %S/Inputs/PCMacroRuntime.swift %t/main.swift %S/../PlaygroundTransform/Inputs/PlaygroundsRuntime.swift
// RUN: %target-run %t/main | %FileCheck %s
// REQUIRES: executable_test
@@ -20,9 +20,9 @@ foo(1)
// CHECK-NEXT: [15:1-15:27] pc after
// CHECK-NEXT: [16:3-16:16] pc before
// CHECK-NEXT: [16:3-16:16] pc after
// CHECK-NEXT: [16:10-16:11] $builtin_log[='true']
// CHECK-NEXT: [16:10-16:11] __builtin_log[='true']
// this next result is unexpected...
// CHECK-NEXT: [19:1-19:7] $builtin_log[='true']
// CHECK-NEXT: [19:1-19:7] __builtin_log[='true']
// CHECK-NEXT: [19:1-19:7] pc after
// now for the array
// CHECK-NEXT: [20:1-20:17] pc before
@@ -31,18 +31,18 @@ foo(1)
// CHECK-NEXT: [16:3-16:16] pc before
// CHECK-NEXT: [16:3-16:16] pc after
// this next result is unexpected...
// CHECK-NEXT: [16:10-16:11] $builtin_log[='true']
// CHECK-NEXT: [16:10-16:11] __builtin_log[='true']
// CHECK-NEXT: [15:1-15:27] pc before
// CHECK-NEXT: [15:1-15:27] pc after
// CHECK-NEXT: [16:3-16:16] pc before
// CHECK-NEXT: [16:3-16:16] pc after
// this next result is unexpected...
// CHECK-NEXT: [16:10-16:11] $builtin_log[='false']
// CHECK-NEXT: [16:10-16:11] __builtin_log[='false']
// CHECK-NEXT: [15:1-15:27] pc before
// CHECK-NEXT: [15:1-15:27] pc after
// CHECK-NEXT: [16:3-16:16] pc before
// CHECK-NEXT: [16:3-16:16] pc after
// this next result is unexpected...
// CHECK-NEXT: [16:10-16:11] $builtin_log[='false']
// CHECK-NEXT: [20:1-20:17] $builtin_log[='[true, false, false]']
// CHECK-NEXT: [16:10-16:11] __builtin_log[='false']
// CHECK-NEXT: [20:1-20:17] __builtin_log[='[true, false, false]']
// CHECK-NEXT: [20:1-20:17] pc after