| 236 | // --- Export detection --- |
| 237 | |
| 238 | bool cbm_is_exported(const char *name, CBMLanguage lang) { |
| 239 | if (!name || !name[0]) { |
| 240 | return false; |
| 241 | } |
| 242 | switch (lang) { |
| 243 | case CBM_LANG_GO: |
| 244 | return (name[0] >= 'A' && name[0] <= 'Z'); |
| 245 | case CBM_LANG_PYTHON: |
| 246 | return (name[0] != '_'); |
| 247 | case CBM_LANG_JAVA: |
| 248 | case CBM_LANG_CSHARP: |
| 249 | case CBM_LANG_KOTLIN: |
| 250 | return (name[0] >= 'A' && name[0] <= 'Z'); |
| 251 | default: |
| 252 | return true; |
| 253 | } |
| 254 | } |
| 255 | |
| 256 | // --- Test file detection --- |
| 257 |
no outgoing calls
no test coverage detected