MCPcopy Index your code
hub / github.com/php/frankenphp / readFile

Function readFile

internal/extgen/utils.go:13–20  ·  view source on GitHub ↗
(filename string)

Source from the content-addressed store, hash-verified

11}
12
13func readFile(filename string) (string, error) {
14 content, err := os.ReadFile(filename)
15 if err != nil {
16 return "", err
17 }
18
19 return string(content), nil
20}
21
22// NamespacedName converts a namespace and name to a C-compatible format.
23// E.g., namespace "Go\Extension" and name "MyClass" become "Go_Extension_MyClass".

Callers 7

TestReadFileFunction · 0.85
fixArginfoFileMethod · 0.85

Calls

no outgoing calls

Tested by 6

TestReadFileFunction · 0.68