#include <metal_stdlib>

using namespace metal;
struct In {
  float4 uv;
};

void g(float a, float b, float c) {
}

struct tint_symbol_1 {
  float4 fbf [[color(0)]];
  float4 uv [[user(locn0)]];
};

void f_inner(float4 pos, float4 fbf, In in) {
  g(pos[0], fbf[0], in.uv[0]);
}

fragment void f(float4 pos [[position]], tint_symbol_1 tint_symbol [[stage_in]]) {
  In const tint_symbol_2 = {.uv=tint_symbol.uv};
  f_inner(pos, tint_symbol.fbf, tint_symbol_2);
  return;
}

