macro_rules! ring_operation {
    ($field:ident, $p:ident, $g:ident, $r:ident, $inv:ident) => { ... };
}