/*
REQUIRED_ARGS: -HC -c -o-
PERMUTE_ARGS:
TEST_OUTPUT:
---
// Automatically generated by Digital Mars D Compiler

#pragma once

#include <stddef.h>
#include <stdint.h>


extern "C" int32_t bar(int32_t x);

extern "C" int32_t bar2(int32_t x);

extern "C" int32_t bar4(int32_t x = 42);

extern int32_t baz(int32_t x);

extern int32_t baz2(int32_t x);

extern int32_t baz4(int32_t x = 42);

extern size_t baz5(size_t x = 42);
---
*/

int foo(int x)
{
    return x * 42;
}

extern (C) int fun();
extern (C++) int fun2();

extern (C) int bar(int x)
{
    return x * 42;
}

extern (C) static int bar2(int x)
{
    return x * 42;
}

extern (C) private int bar3(int x)
{
    return x * 42;
}

extern (C) int bar4(int x = 42)
{
    return x * 42;
}

extern (C++) int baz(int x)
{
    return x * 42;
}

extern (C++) static int baz2(int x)
{
    return x * 42;
}

extern (C++) private int baz3(int x)
{
    return x * 42;
}

extern (C++) int baz4(int x = 42)
{
    return x * 42;
}

extern (C++) size_t baz5(size_t x = 42)
{
    return x * 42;
}
