As of May 31, 2023, we have updated our Code of Conduct.

Questions tagged [auto]

The `auto` keyword was repurposed in C++11 for a deduced type. When used to replace a type name in an initialized variable declaration, the variable is given the same type as the initializer. When used as a return type, the return type is specified as a trailing return type, or deduced from the return-expression.

Filter by
Sorted by
Tagged with
0 votes
0 answers
34 views

Is there any better way to auto fill pdf forms that can only be opened by Adobe Reader [closed]

It is time-consuming to fill in forms manually. I am trying to write some scripts that can auto-fill the data that is already in our database. However, these pdf can only be opened by Adobe Reader. (...
Foxtail's user avatar
  • 11
0 votes
0 answers
8 views

Automatically compressing and renaming daily backup files in MSSQL with 7zip OR Windows scripting

MSSQL Backup Job can't compress daily backup files, I need to know how to script or if there any program that compress every backup folder in the same directory and with it's same name (for example ...
Ali Dagher's user avatar
0 votes
0 answers
14 views

Sweet candy match 3 game level editor script update [closed]

i have a script written on c# which is actually a level maker editor for candy match 3 game script is working fine but you have to work manually to generate the level, in other words level creates one ...
Muhammad Adnan Alam's user avatar
0 votes
0 answers
28 views

How can I include the original email in an Exchange auto-reply for shared-mailboxes?

Does anybody know if this is possible for a Shared-mailbox created in Exchange? Can we make sure that the customer receives the email in the return reply that the customer has sent to us? The customer ...
JM1337dk's user avatar
2 votes
2 answers
76 views

Code using `extern template auto` compiles on some optimization levels and fails on others

I have a template that I do not want to be implicitly instantiated for T=int. Therefore, I declare it as extern for T=int (I do not want a specialization). I do this so I can instantiate the template (...
SirVivor's user avatar
0 votes
0 answers
41 views

How to use auto return type with SWIG

I want to write in c++ code like this and generate it's wrapper in java: class A() { public: const auto & getNumbers() const { return _numbers; } private: vector<int> _numbers; } but ...
AnDevi's user avatar
  • 67
7 votes
3 answers
261 views

C23 auto vs C++11 auto

The C23 standard apparently has introduced using "auto" keyword for auto type deduction, see here, just like in C++11. However, there seems to be some differences. According to here, https://...
Mr User's user avatar
  • 165
1 vote
3 answers
87 views

Type alias for deduced auto return type of member function

Is there a way, from within a class definition, to deduce the auto return type of a member function and use it with a using declaration? For example, I want: #include <vector> class Foo { ...
kc9jud's user avatar
  • 146
0 votes
2 answers
105 views

Why std::integral auto&& parameter does not work with an lvalue argument

I am not sure why the below code doesn't compile: #include <array> #include <algorithm> #include <type_traits> #include <concepts> #include <cstdio> #include <cwchar&...
digito_evo's user avatar
  • 3,154
-2 votes
0 answers
24 views

How. Do. I. Remap. The. ">' SYMBOL?

And dont tell me to go to view> key history cause my version doesnt have that feature. This is all i have with this program - enter image description here none of these options have a view anything ...
user21856302's user avatar
-1 votes
0 answers
36 views

I can't autosave in Visual Studio Code and I get an error message

I tried the autosave settings, but I get a problem with the message (Unable to write into user settings. Please open the user settings to correct errors/warnings in it and try again.)
ع بن محمد 5٧'s user avatar
0 votes
0 answers
11 views

Add condition on contact form 7 auto response

i want to set if anyone select EV Car Solutions then the auto response will work. but somehow the code isn't working. add_action( 'wpcf7_mail_sent', 'contact_form_autoresponders' ); function ...
masudul karim's user avatar
1 vote
3 answers
174 views

Why can't auto infer the type when the return type is specified?

MRE: std::vector<std::string> someFunction() { auto vec; return vec; } What's stopping "auto" from inferring the type of vec as std::vector<std::string>?
justanotherguy's user avatar
0 votes
1 answer
35 views

How to turn off this suggestion text from VS code when type bracket or comma after type, print or any statement [duplicate]

Please check the text that shows in picture I dont need that message from VS code. I want to use the suggestions but not that uselesss text over the code. Its fine that suggestions shows, SOLUTION : ...
Ashiq's user avatar
  • 9
0 votes
1 answer
54 views

Operands to ?: have different types with matching auto functors [duplicate]

I have the following, which does not compile: void func(std::optional<std::function<void(int, int)>> arg1) { return; } void callee(bool flag) { auto arg1 = [](int a1) { ...
Tyler Kelly's user avatar
1 vote
1 answer
34 views

Why is auto on grid-template-columns making multiple elements the same width?

What i'm trying to make A list of items (not a ul/ol kind of list) is placed in the center of a page, these items have 2 columns. The first column should have a "fixed" width (1em in this ...
Awesom-o's user avatar
  • 504
0 votes
0 answers
28 views

Auto scroller for chat in reactjs

I am making chat website in reactjs and I can't make two functions: Scroll down div automatically when user go to the page. If user have scrolled div to down stay scrolled for view new messages if ...
George Burkadze's user avatar
-1 votes
1 answer
61 views

How do i update a graph automatically in tkinter?

ok guys , im kinda frustrated , i've searched everywhere and everytime i try something i find in the internet i get so many error and problems and i think its time to ask how do i do that ? i want ...
Haymon's user avatar
  • 1
-1 votes
1 answer
76 views

Get a random number when emplace an element with range-based for loop

I wrote a program to insert the numbers in C++ with CLion. First, enter a set of positive integers and place them into the vector called pour. Then, take the negative numbers of these positive ...
抹茶抹茶's user avatar
0 votes
0 answers
30 views

for loop iterate two time in jquery automatically

I am trying to get data by calling api and put data into table. I found three length of data in object type. Then when I want to show it on table it shows six row but I want three row. When I debugged ...
Nurin Azmir's user avatar
2 votes
1 answer
52 views

How to infer return type of function returned from a function in c++

Consider this code template <typename OUT> auto fun(const int& x) { return [&](function<OUT(int)> fout) -> decltype(fout(x)) {return fout(x);}; } calling function auto w = ...
aalbatross's user avatar
0 votes
0 answers
36 views

Auto function and templates on c++ [duplicate]

Simple program I do not figure out what did I do wrong, probably it's just a syntax related problem. The goal of my programm is to make a function which returns a value + 5 but the value will be ...
zavkk's user avatar
  • 1
1 vote
0 answers
40 views

Symbol table entry when using auto return type deduction with templates in C++

Does anyone know the reason why the output of nm -C on an executable that contained a templated function defined with auto return type deduction has the word auto in the symbol table? Why does it need ...
TCD's user avatar
  • 151
0 votes
0 answers
36 views

Sending key presses to minimized windows application

Is there any possible way to send key presses to minimized windows application with node.js? I have seen robo.js and nut.js as possible solutions but robo.js is not maintained and nut.js doesn't seem ...
Amit's user avatar
  • 11
-1 votes
1 answer
26 views

Centering The Nav in the middle

I want to the main-nav that includes the links to be in the middle in the phone media I use the margin: auto; but that didn't work. And I use the ::before for some effects when hovering. Here is the ...
Omar FF's user avatar
0 votes
0 answers
25 views

Dark/Light Automatic Change

So I have this manual script for changing my forum from dark to light, however how to do it as a automatic setup from 6pm till 7am dark etc) <script> $(document).ready(function() { ...
Jacek Krajewski's user avatar
1 vote
0 answers
24 views

Automatic height of the iframe window

I need the material, specifically the content of another page, to be loaded into the iframe and the iframe window must automatically set a new height after changing the content in this window. I have ...
Krystian's user avatar
1 vote
0 answers
33 views

How to use auto scroll view in react native with dote?

here is my code App.js import React from 'react' import { Image, StyleSheet, TouchableOpacity, Dimensions, Text, View } from 'react-native' import { scale, verticalScale } from "react-native-size-...
Dhara Patel's user avatar
0 votes
0 answers
40 views

Swift password keyboard suggestions

How can I achieve such password suggestions as in the picture. Currently I only have a “Password” suggestion in the middle (opens modal with keychain saved credentials)? Already tried making the: ...
Tropicano's user avatar
  • 271
0 votes
1 answer
118 views

The right way for get template to return value: decltype(auto), auto&&, or

The simple case is described here However, I cant find a way to get a proper return result in given situations. Lets consider basic 'get' function. template<typename T> decltype(auto) get_object(...
user2561762's user avatar
2 votes
2 answers
199 views

C++ compiler says "inconsistent deduction for auto return type"

There is this nice feature in C++ where you can say the function has return type "auto" and compiler will figure it out. However, what if I return a pointer and nullptr on error? Somehow ...
user45927's user avatar
  • 186
0 votes
0 answers
71 views

How to detect user with adblock to not serve him adsense ad?

I have some Google adsense ad in my website and it's causes CLS. One way to fix it to reserve them a fixed height div, but when user is having adblocker, it is only a big empty space, I dont want that....
zecke's user avatar
  • 13
0 votes
0 answers
14 views

Making https URL text automatically clickable

I use the following code at the top of my web page to automatically turn URLs into clickable links. %%PERL:&auto_link%% Example: http://123.com becomes clickable. However, https://123.com does not ...
Brod's user avatar
  • 1
1 vote
1 answer
67 views

Why are adornment to auto allowed in the return type of a function

I have always thought that the only form of using auto as the return type is as follows: auto f() { return 42; } I have just seen code when has a const reference adornment specifier added. int ...
Blair Davidson's user avatar
1 vote
0 answers
245 views

Ahk2Exe This line does not contain a recognized action

this error when I try to compile my auto hot key(ahk) code. Ahk2Exe Error Error: The script contains syntax errors. Specifically: C:\Users\ibraheem\Downloads\e.ahk (1) : ==> This line does not ...
ibraheem mohsen's user avatar
0 votes
1 answer
189 views

Configuration for AWS RDS Aurora autoscaling to handle high concurrent traffic spikes?

We have an application deployed on AWS. The application runs on EC2 instances with Auto Scaling and Amazon Aurora also with Auto Scaling. This app works as a middleware that receives and processes ...
Chescko29's user avatar
-5 votes
1 answer
81 views

C++ STL Map gives TLE when looping with auto? [closed]

I was working on this problem on CodeForces. My solution was giving TLE and I could not figure out why. Eventually I narrowed it to the faulty line and it was essentially the following // map<int, ...
Axo's user avatar
  • 121
0 votes
0 answers
464 views

How to automatically increment the assembly version number in C#

How to automatically increment the assembly version number in C# . NET6 no longer has AssemblyInfo.cs, as we all know And i try the answer at How to auto increment the version (eg. “1.0.*”) of a .NET ...
Zerek's user avatar
  • 33
0 votes
0 answers
59 views

Why is it not possible to initialize a variable with "auto =" if the type name of the variable consists of multiple words? [duplicate]

long long a{34}; // Ok unsigned long b{90}; // Ok auto c = long{12}; // Ok auto d = unsigned{17}; // Ok auto e = long long{3}; // error: expected primary-expression before 'long' auto f = unsigned ...
Alexey104's user avatar
  • 979
7 votes
1 answer
246 views

Is a template with reference non-type template parameter supposed to match a template template parameter with an auto non-type template parameter?

template<template<auto> class> struct A {}; template<int&> struct B {}; A<B> a; int main() {} All three compilers MSVC, GCC and Clang in their latest versions accept ...
user17732522's user avatar
  • 48.3k
2 votes
1 answer
93 views

How does the `auto` keyword work in lambda functions?

I am new to templates and lambdas function and I am trying to understand what's happening in this piece of code: function<void (const int &)> foo = [&](auto x) { x = 42; } Here, I ...
iluvmath's user avatar
  • 177
0 votes
2 answers
225 views

In C, how does "auto" keyword is used before and after C11?

i have read, about automatic variables and local variables; i know i can use auto for declare a local variable but i know i just can declare/define a local variable without the auto keyword. I have ...
Cblue X's user avatar
  • 135
0 votes
1 answer
73 views

I am trying to make a script to auto click cards but doesn't work

here is the link im trying to make a click event on using javascript: jawaker after i join a game it gives me cards, i am trying to make a script to auto click those cards here is the html: <...
user3650773's user avatar
0 votes
1 answer
65 views

function-style-cast in Template Meta programming

Code taken from the book Template Metaprogramming with C++, it doesn't compile i tried visual studio 22 i get the error: Error C2440 \<function-style-cast\>' : cannot convert from '...
ejy's user avatar
  • 1
2 votes
1 answer
95 views

Is auto for function input parameters a replacement for function templates?

In C++20 the auto keyword can be used for function input parameters. Is this a proper replacement for function templates and are there any practical differences to consider when deciding on which ...
joaerl's user avatar
  • 982
1 vote
1 answer
75 views

How to create a template which gets input variables in square brackets? [closed]

First of all, I know my question is too bizarre due to English is not my mother tongue. I have used Google to learn this but I did not understand anything actually. I want to create a function like ...
user avatar
1 vote
0 answers
62 views

Is function with arguments of type `auto` implicitly converted to template? [duplicate]

I was writing a function that should work in the same way with containers of different types. First I wanted to make it a template function, which is obvious, but then I realized that I don't actually ...
Alexey104's user avatar
  • 979
0 votes
0 answers
232 views

Program Created by auto-py-to-exe seens as Malware "Heur.AdvML.B" by Anti-Virus

Dears, I made a simple program and once I convert it to exe using Auto-Py-To-exe tool, my antivirus consider it as a malware and reported the following error message. Checking the forums it recommend ...
PyiPath2022's user avatar
-2 votes
1 answer
63 views

How to access and convert pair value?

vector<pair<int,char>> alpha; for(int i = 0; i < 26; i++) { if (letter[i] > 0) { alpha.push_back(pair<int,char>(letter[i], (i+'A'))); } } sort(alpha.begin(...
Iftekhar Jitu's user avatar
0 votes
0 answers
15 views

Auto Expand Table when source change

I am using a table1 in Sheet1 I have created a second table2 in sheet2 that collects the data from table1 (not mirror). I cant make table2 to autoexpand or vise versa when table1 is filled. What Am I ...
Makis Patos's user avatar

1
2 3 4 5
26