MCPcopy Create free account
hub / github.com/bloomberg/comdb2 / get_prompt

Function get_prompt

lua/lua.c:151–158  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

149
150
151static const char *get_prompt (lua_State *L, int firstline) {
152 const char *p;
153 lua_getfield(L, LUA_GLOBALSINDEX, firstline ? "_PROMPT" : "_PROMPT2");
154 p = lua_tostring(L, -1);
155 if (p == NULL) p = (firstline ? LUA_PROMPT : LUA_PROMPT2);
156 lua_pop(L, 1); /* remove global */
157 return p;
158}
159
160
161static int incomplete (lua_State *L, int status) {

Callers 1

pushlineFunction · 0.85

Calls 1

lua_getfieldFunction · 0.85

Tested by

no test coverage detected